/**
 * 
 */
package com.orange.handler.expert.impl;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.orange.dbhelp.page.Page;
import com.orange.handler.expert.AuthExpertSchoolMapService;
import com.orange.modules.bean.SchoolItemBean;
import com.orange.modules.dao.expert.AuthExpertSchoolMapRepository;
import com.orange.modules.entity.AuthItem;
import com.orange.modules.entity.expert.AuthExpertItemMap;
import com.orange.modules.entity.expert.AuthExpertSchoolMap;

/**
 * @author gaogs
 *
 * 2016-12-15
 */
@Service
public class AuthExpertSchoolMapServiceImpl implements
		AuthExpertSchoolMapService {

	@Autowired
	private AuthExpertSchoolMapRepository authExpertSchoolMapRepository;
	/* (non-Javadoc)
	 * @see com.orange.handler.expert.AuthExpertSchoolMapService#saveAuthExpertSchoolMapList(java.util.List)
	 */
	@Override
	public void saveAuthExpertSchoolMapList(List<AuthExpertSchoolMap> list) {
		authExpertSchoolMapRepository.saveAuthExpertSchoolMapList(list);
	}

	/* (non-Javadoc)
	 * @see com.orange.handler.expert.AuthExpertSchoolMapService#deleteAuthExpertSchoolMapInfo(java.lang.String)
	 */
	@Override
	public void deleteAuthExpertSchoolMapInfo(String expertId)
			throws SQLException {
		authExpertSchoolMapRepository.deleteAuthExpertSchoolMapInfo(expertId);
	}

	/* (non-Javadoc)
	 * @see com.orange.handler.expert.AuthExpertSchoolMapService#queryAuthExpertSchoolMapInfoByExpert(java.lang.String)
	 */
	@Override
	public List<AuthExpertSchoolMap> queryAuthExpertSchoolMapInfoByExpert(
			String expertId) throws SQLException {
		List<AuthExpertSchoolMap> list=authExpertSchoolMapRepository.queryAuthExpertSchoolMapInfoByExpert(expertId);
		return list;
	}

	@Override
	public Page<SchoolItemBean> queryAuthSchoolPageByExportId(String exportId,
			Map<String, String> map) throws SQLException {
		Page<SchoolItemBean> page = authExpertSchoolMapRepository.queryAuthSchoolPageByExportId(exportId, map);
		return page;
	}

	@Override
	public AuthExpertSchoolMap queryAuthExpertSchoolMapInfoByExpert1(
			String expertId) throws SQLException {
		AuthExpertSchoolMap ae = authExpertSchoolMapRepository.queryAuthExpertSchoolMapInfoByExpert1(expertId);
		return ae;
	}

	@Override
	public List<AuthItem> queryAuthItemBySchoolIdAndExpertId(String schoolId,
			String expertId) throws SQLException {
		List<AuthItem> list = authExpertSchoolMapRepository.queryAuthItemBySchoolIdAndExpertId(schoolId, expertId);
		return list;
	}

	@Override
	public Page<SchoolItemBean> queryAuthSchoolPageByGroupId(String expertId,
			Map<String, String> map) throws SQLException {
		Page<SchoolItemBean> page = authExpertSchoolMapRepository.queryAuthSchoolPageByGroupId(expertId, map);
		return page;
	}

	@Override
	public List<AuthExpertSchoolMap> querySchoolIdByGroupId(String groupId)
			throws SQLException {
		List<AuthExpertSchoolMap> list = authExpertSchoolMapRepository.querySchoolIdByGroupId(groupId);
		return list;
	}

	@Override
	public Page<SchoolItemBean> queryAuthSchoolPageByGroupId1(String groupId,
			Map<String, String> map) throws SQLException {
		Page<SchoolItemBean> page = authExpertSchoolMapRepository.queryAuthSchoolPageByGroupId1(groupId, map);
		return page;
	}

}
